﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace CrdDeserialize
{
    public class DeployConfig
    {
        public Metadata Metadata { get; set; }
        public Spec Spec { get; set; }

        public override string ToString()
        {
            string vps = string.Join("\n", Spec.Config.VoiceRefCid);
            return $"Name={Metadata.Name}\nCid={Spec.Cid}\nVps={vps}";
        }
    }

    public class Metadata
    {
        public string Name { get; set; }
    }

    public class Spec
    {
        public string Cid { get; set; }
        public Config Config { get; set; }
    }

    public class Config
    {
        public string Cid { get; set; }
        public string TuningCid { get; set; }
        public string[] VoiceRefCid { get; set; }
    }
}
